﻿@model tantrinh.Models.SanPham
@{
    ViewBag.Title = "Delete";
    Layout = "~/Views/Shared/_LayoutAdmin.cshtml";
}
@if (Request.IsAuthenticated && @Session["UserId"] != null)
{
    <h2>
        Delete</h2>

    <h3>
        Are you sure you want to delete this?</h3>
    <fieldset>
        <legend>SanPham</legend>
        <div class="display-label">
            MaSanPham</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.MaSanPham)
        </div>
        <div class="display-label">
            TenSanPham</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.TenSanPham)
        </div>
        <div class="display-label">
            GiaSanPham</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.GiaSanPham)
        </div>
        <div class="display-label">
            AnhDaiDien</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.AnhDaiDien)
        </div>
        <div class="display-label">
            MoTa</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.MoTa)
        </div>
        <div class="display-label">
            LuotView</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.LuotView)
        </div>
        <div class="display-label">
            ChiTietDanhMuc</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.ChiTietDanhMuc.TenChiTietDanhMuc)
        </div>
        <div class="display-label">
            NhanHieu</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.NhanHieu.TenNhanHieu)
        </div>
        <div class="display-label">
            NgayDang</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.NgayDang)
        </div>
        <div class="display-label">
            TinhTrang</div>
        <div class="display-field">
            @Html.DisplayFor(model => model.TinhTrang)
        </div>
    </fieldset>
    using (Html.BeginForm())
    {
    <p>
        <input type="submit" value="Delete" />
        |
        @Html.ActionLink("Back to List", "Index")
    </p>
    }
}
else
{
    <p>
        Xin vui lòng đăng nhập</p>
    <script type="text/javascript">
        window.location.href = "http://tantrinhcaraudio.com/admin"
    </script>
}